<%@page pageEncoding="UTF-8"  contentType="application/json; charset=UTF-8"  %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@taglib uri="http://chances.com.cn/jsp/epgdata" prefix="epgdata"%>


<epgdata:categoryItem var="menu_cat" size="4" code="${_templateParams['menu_cat']}" />

<epgdata:bizList var="dbIndex_biz" code="${_templateParams['dbIndex_biz']}"/>

{
	"status": "200",
	"title": "_context.biz.title",
	"code": "${_context.bizCode}",
	"areaDatas": 
	[
		<c:if test="${not empty _templateParams['menu_cat']}">
		{
			"areaCode":"${_templateParams['menu_cat']}",
			"areaType": "",
			"areaTitle": "导航",
			"items":[
				<c:forEach var="item" items="${menu_cat}" varStatus="idx">
					{
					"itemTitle": "${item.title}",
					"itemCode": "${item.itemCode}",
					"itemType": "${item.itemType}",
					"itemIcon": "${item.itemIcon}",
					"dataLink": "${item.url}"
					}<c:if test="${!idx.last }">,</c:if>
				</c:forEach>
			]
		},
		</c:if>
		
		<c:if test="${not empty dbIndex_biz}">
		{
			"areaCode":"${_templateParams['dbIndex_biz']}",
			"areaType": "",
			"areaTitle": "展示内容",
			"items":[
				<c:forEach items="${dbIndex_biz}" var="biz" varStatus="idx">
				{
					"areaCode":"${biz.code}",
					"areaType": "biz",
					"areaTitle": "${biz.title}",
					"areaIcon": "${_resourcePath}${biz.icon}",
					"items":[
						<epgdata:bizList var="curBizs" code="${biz.code}"/>
						<c:forEach var="item" items="${curBizs}" varStatus="index">
							{
							"itemTitle": "${item.title}",
							"itemCode": "${item.code}",
							"itemType": "biz",
							"bigIcon": "${_resourcePath}${item.bigIcon}",
							"dataLink": "${item.url}"
							}<c:if test="${!index.last }">,</c:if>
						</c:forEach>
					]
				}<c:if test="${!idx.last }">,</c:if>
				</c:forEach>
			]}
		</c:if>
	]

}